<template>
  <div class="home">
    <IndexSwiper :img="img"/>
    <router-view class="router-view" />
  </div>
</template>

<script>
// @ is an alias to /src
import IndexSwiper from '@/components/IndexSwiper.vue'

export default {
  name: 'index',
  components: {
    IndexSwiper
  },
  data: function () {
    return {
      img: [
        {
          img: 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1560165295967&di=ef419f5ad3f0947dd05feaccd7bb9f14&imgtype=0&src=http%3A%2F%2Fstatic01.coloros.com%2Fbbs%2Fdata%2Fattachment%2Fforum%2F201706%2F28%2F203040mmc4aoae117g4z4i.jpg'
        },
        {
          img: 'https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=2616456851,2613926782&fm=26&gp=0.jpg'
        },
        {
          img: 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1560165295967&di=004716f0b81d9d795ade75d89659b83d&imgtype=0&src=http%3A%2F%2Fimg4.duitang.com%2Fuploads%2Fitem%2F201411%2F15%2F20141115073406_sBsUN.jpeg'
        }
      ]
    }
  }
}
</script>

<style scoped>
.router-view{
    position: absolute;
    height: 100%;
    width: 100%;
    z-index: 2;
    background-color: white;
}
</style>
